import request from '@/request'

// 查询参数列表
export function listSecurityArticles(query) {
  return request({
    url: '/resources/articles/list',
    method: 'get',
    params: query
  })
}

export function getHotSecurityArticles() {
  return request({
    url: '/resources/userFunctions/hotSecurityArticles',
    method: 'get'
  })
}
export function getHotSecurityArticlesList(query) {
  return request({
    url: '/resources/userFunctions/hotSecurityArticles/list',
    method: 'get',
    params: query
  })
}

// 查询参数详细
export function getSecurityArticles(articlesId) {
  return request({
    url: '/resources/articles/' + articlesId,
    method: 'get'
  })
}

// 新增参数配置
export function addSecurityArticles(data) {
  return request({
    url: '/resources/articles',
    method: 'post',
    data: data
  })
}

// 修改参数配置
export function updateSecurityArticles(data) {
  return request({
    url: '/resources/articles',
    method: 'put',
    data: data
  })
}

// 删除参数配置
export function delSecurityArticles(articlesId) {
  return request({
    url: '/resources/articles/' + articlesId,
    method: 'delete'
  })
}
